<div class="sign-up grid_16 prefix_5 clearfix">
  <div class="l-curve-top">          
            <div class="r-curve-top">
			            <div class="top-bg"></div>
			</div>
        </div>
  <div class="shad-bg-lft clearfix">
          <div class="shad-bg-rgt">
            <div class="shad-bg clearfix">
			<div class="main-section">
			<div class="clearfix">
		  		  	 <div class="open-id-block grid_8 clearfix">
        <h5 class="grid_left"><?php echo __l('Sign up using: '); ?></h5>
		<ul class="open-id-list grid_left list clearfix">
			<li class="face-book">
				 <?php if(Configure::read('facebook.is_enabled_facebook_connect')):  ?>
					<?php echo $this->Html->link(__l('Sign in with Facebook'), array('controller' => 'users', 'action' => 'login','type'=>'facebook'), array('title' => __l('Sign in with Facebook'), 'escape' => false)); ?>
				 <?php endif; ?>
			</li>
			<?php if(Configure::read('twitter.is_enabled_twitter_connect')):?>
				<li class="twiiter"><?php echo $this->Html->link(__l('Sign in with Twitter'), array('controller' => 'users', 'action' => 'login',  'type'=> 'twitter', 'admin'=>false), array('class' => 'Twitter', 'title' => __l('Sign in with Twitter')));?></li>
			<?php endif;?>
			<?php if(Configure::read('user.is_enable_openid')):?>
				<li class="yahoo"><?php echo $this->Html->link(__l('Sign in with Yahoo'), array('controller' => 'users', 'action' => 'login', 'type'=>'yahoo'), array('alt'=> __l('[Image: Yahoo]'),'title' => __l('Sign in with Yahoo')));?></li>
				<li class="gmail"><?php echo $this->Html->link(__l('Sign in with Gmail'), array('controller' => 'users', 'action' => 'login', 'type'=>'gmail'), array('alt'=> __l('[Image: Gmail]'),'title' => __l('Sign in with Gmail')));?></li>
				<li class="open-id"><?php 	echo $this->Html->link(__l('Sign in with Open ID'), array('controller' => 'users', 'action' => 'login','type'=>'openid'), array('class'=>'js-ajax-colorbox-openid {source:"js-dialog-body-open-login"}','title' => __l('Sign in with Open ID')));?></li>
			<?php endif;?>
		</ul>
	</div>
	</div>
					<?php echo $this->Form->create('User', array('action' => 'register', 'class' => 'normal js-company-map js-register-form clearfix')); ?>
			
				<?php
					if(!empty($this->request->data['User']['openid_url'])):
						echo $this->Form->input('openid_url', array('type' => 'hidden', 'value' => $this->request->data['User']['openid_url']));
					endif;
					echo $this->Form->input('username');
					if(empty($this->request->data['User']['openid_url']) && empty($this->request->data['User']['fb_user_id']) && empty($this->request->data['User']['twitter_user_id'])):
						echo $this->Form->input('passwd', array('label' => __l('Password')));
					endif;
					echo $this->Form->input('email');?>

					<div class="clearfix">
					<?php
			if(!empty($this->request->data['User']['fb_user_id'])) :
                echo $this->Form->input('fb_user_id', array('type' => 'hidden', 'value' => $this->request->data['User']['fb_user_id']));
                echo $this->Form->input('is_facebook_register', array('type' => 'hidden', 'value' => $this->request->data['User']['is_facebook_register']));
            endif;
			if(!empty($this->request->data['User']['twitter_user_id'])) :
                echo $this->Form->input('twitter_user_id', array('type' => 'hidden', 'value' => $this->request->data['User']['twitter_user_id']));
	            echo $this->Form->input('is_twitter_register', array('type' => 'hidden', 'value' => $this->request->data['User']['is_twitter_register']));
            endif;		 
			if(!empty($this->request->data['User']['twitter_access_token'])) :
                echo $this->Form->input('twitter_access_token', array('type' => 'hidden', 'value' => $this->request->data['User']['twitter_access_token']));
            endif;		 
			if(!empty($this->request->data['User']['twitter_access_key'])) :
                echo $this->Form->input('twitter_access_key', array('type' => 'hidden', 'value' => $this->request->data['User']['twitter_access_key']));
            endif;		 
			if(!empty($this->request->data['User']['is_yahoo_register'])) :
                echo $this->Form->input('is_yahoo_register', array('type' => 'hidden', 'value' => $this->request->data['User']['is_yahoo_register']));
            endif;
            if(!empty($this->request->data['User']['is_gmail_register'])) :
                echo $this->Form->input('is_gmail_register', array('type' => 'hidden', 'value' => $this->request->data['User']['is_gmail_register']));
            endif;	
				echo $this->Form->input('country_iso_code', array('type' => 'hidden','id' => 'country_iso_code'));
				echo $this->Form->input('State.name', array('type' => 'hidden'));
				echo $this->Form->input('City.name', array('type' => 'hidden'));
				echo $this->Form->input('latitude',array('type' => 'hidden', 'id'=>'latitude'));
				echo $this->Form->input('longitude',array('type' => 'hidden', 'id'=>'longitude'));
			?>

</div>
                    <?php
					if(empty($this->request->data['User']['openid_url'])): ?>
							<div class="input captcha-block clearfix js-captcha-container">
							<div class="captcha-left grid_left">
							   <?php echo $this->Html->image($this->Html->url(array('controller' => 'users', 'action' => 'show_captcha', md5(uniqid(time()))), true), array('alt' => __l('[Image: CAPTCHA image. You will need to recognize the text in it; audible CAPTCHA available too.]'), 'title' => __l('CAPTCHA image'), 'class' => 'captcha-img'));?>
							</div>
							<div class="captcha-right grid_left">
								<?php echo $this->Html->link(__l('Reload CAPTCHA'), '#', array('class' => 'js-captcha-reload captcha-reload', 'title' => __l('Reload CAPTCHA')));?>
								<div>
		              <?php echo $this->Html->link(__l('Click to play'), Router::url('/', true)."flash/securimage/play.swf?audio=". $this->Html->url(array('controller' => 'users', 'action'=>'captcha_play'), true) ."&bgColor1=#777&bgColor2=#fff&iconColor=#000&roundedCorner=5&height=19&width=19", array('class' => 'js-captcha-play')); ?>
				   </div>
							</div>
						</div>
						<?php echo $this->Form->input('captcha', array('value' =>'' ,'label' => __l('Security Code'))); ?>
					<div class="agree-content clearfix">	<?php echo $this->Form->input('is_agree_terms_conditions', array('label' => sprintf(__l('I have read, understood & agree to the %s'), $this->Html->link(__l('Terms & Policies'), array('controller' => 'pages', 'action' => 'view', 'term-and-conditions'), array('target' => '_blank'))))); ?></div>
						<?php
					endif; ?>
				
		<div class="submit-block clearfix">	<?php echo $this->Form->end(__l('Sign Up')); ?></div>
		</div>
	  </div>
	</div>
  </div>
  <div class="l-curve-bot">          
            <div class="r-curve-bot">
			            <div class="bot-bg"></div>
			</div>
        </div>
</div>